package com.cuit.ocp.common.exception;

/**
 * @program: miniprogram
 * @description: 异常相关
 * @author: jingc
 * @create: 2020-11-06 19:30
 **/
public class CustomException extends RuntimeException {
    private static final long serialVersionUID = 1L;
    protected final String code;

    public CustomException() {
        this.code = null;
    }

    public CustomException(final String message) {
        super(message);
        this.code = null;
    }

    public CustomException(final Throwable cause) {
        super(cause);
        this.code = null;
    }

    public CustomException(final String message, final Throwable cause) {
        super(message, cause);
        this.code = null;
    }

    public CustomException(final String code, final String message) {
        super(message);
        this.code = code;
    }

    public CustomException(final String code, final String message, final Throwable cause) {
        super(message, cause);
        this.code = code;
    }
    public String getCode() {
        return this.code;
    }
}
